<?php
class Application_Form_Mail extends Zend_Form{
	public function init(){
		$this->setMethod('post');
		$this->setAttrib('id', 'mailForm');
		
		$obj = new Zend_Form_Element_Text('object');
		$obj	->setLabel('Object')
				->setRequired(true)
				->setAttrib('class', 'validate[required,minSize[10]]')
				->addFilter('StripTags')
				->addFilter('StringTrim')
				->addValidator('NotEmpty')
				->addValidator(new Zend_Validate_StringLength(10))
				->setDecorators(array('ViewHelper'));
		$this->addElement($obj);
		
		$text = new Zend_Form_Element_Textarea('text');
		$text	->setLabel('Text')
				->setRequired(true)
				->addFilter('StripTags')
				->setAttrib('class', 'validate[required,minSize[10]]')
				->addFilter('StringTrim')
				->addValidator('NotEmpty')
				->addValidator(new Zend_Validate_StringLength(10))
				->setDecorators(array('ViewHelper'));
		$this->addElement($text);
		
		$submit = new Zend_Form_Element_Submit('submit');
		$submit	->setLabel('Send')
				->setDecorators(array('ViewHelper'));
		$this->addElement($submit);
	}
}